What is Loss Function?
Definition:
A loss function is mathematical function that measures the difference between the predicted output and the actual output.It is also a method of evaluating how well your algorithm models your dataset. At its core, a loss function is incredibly simple: It’s a method of evaluating how well your algorithm models your dataset. If your predictions are totally off, your loss function will output a higher number. If they’re pretty good, it’ll output a lower number. As you change pieces of your algorithm to try and improve your model, your loss function will tell you if you’re getting anywhere.